@charset 'UTF-8';

.search-bar__container {
    .channel-header__links {
        .sidebar--right & {
            line-height: 25px;
        }
    }
}

.icon--rotate {
    @include animation(spin .7s infinite linear);
}

.search-item-snippet {
    @include clearfix;
    text-overflow: ellipsis;

    ul,
    ol {
        padding-left: 20px;
    }
}

.search__icon {
    left: 9px;
    position: absolute;
    top: 6px;

    svg {
        body.enable-animations & {
            @include single-transition(all, $transition-quick, ease-out);
        }
    }
}

.input-clear {
    @include opacity(.5);
    cursor: pointer;
    margin-right: 20px;
    position: absolute;
    right: 0;
    top: 0;
    visibility: hidden;
    width: 22px;
    margin: 0;
    font-size: 20px;

    &:hover {
        @include opacity(1);
    }

    &.visible {
        visibility: visible;
    }

    body.enable-animations & {
        @include single-transition(all, $transition-quick, ease-out);
    }
}

.search-bar__container {
    padding-left: 8px;
}

.search__form {
    padding: 0 30px;
    position: relative;

    .search-bar__container & {
        @include border-radius(50px);
        border: 1px solid $light-gray;
        margin: 16px 0 0;
        width: 180px;
    }

    body.enable-animations .search-bar__container & {
        @include transition-property(border-color, width);
        @include transition-duration($transition-quick, 0.3s);
        @include transition-delay(0s);
        @include transition-timing-function(ease-in-out, ease-out);
    }

    .inner-wrap.move--left & {
        width: 300px;
    }

    .search-bar {
        background: transparent;
        border: none;
        box-shadow: none;
        font-size: 14px;
        height: 28px;
        outline: none;
        padding-bottom: 2px;
        width: 100%;

        &.a11y--focused {
            box-shadow: none;
        }
    }

    .LoadingSpinner {
        @include opacity(0.5);
        font-size: 1em;
        position: absolute;
        right: 8px;
        top: 5px;
    }
}

.search-items-container {
    @include flex(1 1 auto);
    -webkit-overflow-scrolling: touch;
    height: calc(100% - 56px);
    padding-top: 28px;
    position: relative;
}

.search-items-container div.loading {
    text-align: center;
}

.search-items-container img {
    display: inline-block;
}

.search-results-header {
    border-bottom: $border-gray;
    color: #999999;
    font-size: 1em;
    font-weight: 400;
    height: 44px;
    line-height: 44px;
    padding: 0 10px;
    text-transform: uppercase;
}

.search-item__container {
    .post {
        margin: 0;
        padding: 0 1em 16px;

        &:first-child {
            border: none;
        }

        &:hover {
            .post__header {
                padding-right: 105px;
            }
        }

        .post__header {
            padding-right: 70px;
        }

        .search-channel__name {
            font-weight: 600;
            padding: 16px 0 12px;
        }

        .search-channel__archived {
            opacity: 0.5;
            float: right;
        }
    }
}

.col__controls {
    font-size: 13px;
    position: absolute;
    right: 0;
    top: 0;

    a {
        vertical-align: top;
    }


    .search-item__jump {
        @include border-radius(4px);
        font-size: 13px;
        position: relative;
        padding: 2px 7px 0;
        text-decoration: none;
    }
}

.search-item-time {
    @include opacity(.7);
    font-size: .9em;
}

.search-results-none {
    padding: 10px;
}

.search-highlight {
    background-color: $yellow;
}
